-
Notifications
You must be signed in to change notification settings - Fork 0
Correção do Projeto #9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Inicio do projeto Labook8
Feito endpoints de signUp e createPost
Labook - Login
Conserto do erro no signUp
Login funcionando
endpoints de fazer e desfazer amizades concluído
Feed e criaçao de post consertados
amandarangel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Parabéns, pessoal!!! O trabalho de vocês ficou bem legal e vocês conseguiram trabalhar muito bem em grupo! Deixei só algumas observações no código! Estou muito feliz com o resultado que vocês apresentaram!! Continuem assim!
|
|
||
| if(!user){ | ||
| throw new Error("Usuário não existe") | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excelente verificação!
|
|
||
| const userRelationDatabase = new UserRelationDatabase(); | ||
| await userRelationDatabase.undoFriend(userId, undoFriendshipUserId) | ||
| await userRelationDatabase.undoFriend(undoFriendshipUserId, userId) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ficou repetido aqui! rs
Ahhh, uma coisa legal de fazer, tanto na hora de fazer amizade, quanto na hora de desfazer, é verificar se já existe amizade entre os dois usuários!
|
|
||
| } | ||
|
|
||
| async get(token:string){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
O médoto com o nome apenas get no UserBusiness me faz pensar que é um método para pegar o usuário e não o feed! Vale ser um pouquinho mais específico aqui :)
| const posts: Post[] = []; | ||
|
|
||
| for (let post of result) { | ||
| posts.push(Post.toPostModel(post)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Show!!!
| } catch (error) { | ||
| res.status(400).send({ | ||
| messege: error.messege | ||
| }) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Endpoint super bem estruturado!!
No description provided.